Optimal. Leaf size=53 \[ -\frac {(a+3 b) \tanh ^{-1}(\cos (e+f x))}{2 f}-\frac {(a+b) \cot (e+f x) \csc (e+f x)}{2 f}+\frac {b \sec (e+f x)}{f} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.05, antiderivative size = 53, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 21, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.190, Rules used = {4133, 456, 453, 206} \[ -\frac {(a+3 b) \tanh ^{-1}(\cos (e+f x))}{2 f}-\frac {(a+b) \cot (e+f x) \csc (e+f x)}{2 f}+\frac {b \sec (e+f x)}{f} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 206
Rule 453
Rule 456
Rule 4133
Rubi steps
\begin {align*} \int \csc ^3(e+f x) \left (a+b \sec ^2(e+f x)\right ) \, dx &=-\frac {\operatorname {Subst}\left (\int \frac {b+a x^2}{x^2 \left (1-x^2\right )^2} \, dx,x,\cos (e+f x)\right )}{f}\\ &=-\frac {(a+b) \cot (e+f x) \csc (e+f x)}{2 f}+\frac {\operatorname {Subst}\left (\int \frac {-2 b-(a+b) x^2}{x^2 \left (1-x^2\right )} \, dx,x,\cos (e+f x)\right )}{2 f}\\ &=-\frac {(a+b) \cot (e+f x) \csc (e+f x)}{2 f}+\frac {b \sec (e+f x)}{f}-\frac {(a+3 b) \operatorname {Subst}\left (\int \frac {1}{1-x^2} \, dx,x,\cos (e+f x)\right )}{2 f}\\ &=-\frac {(a+3 b) \tanh ^{-1}(\cos (e+f x))}{2 f}-\frac {(a+b) \cot (e+f x) \csc (e+f x)}{2 f}+\frac {b \sec (e+f x)}{f}\\ \end {align*}
________________________________________________________________________________________
Mathematica [B] time = 0.38, size = 236, normalized size = 4.45 \[ -\frac {a \csc ^2\left (\frac {1}{2} (e+f x)\right )}{8 f}+\frac {a \sec ^2\left (\frac {1}{2} (e+f x)\right )}{8 f}+\frac {a \log \left (\sin \left (\frac {1}{2} (e+f x)\right )\right )}{2 f}-\frac {a \log \left (\cos \left (\frac {1}{2} (e+f x)\right )\right )}{2 f}-\frac {b \csc ^2\left (\frac {1}{2} (e+f x)\right )}{8 f}+\frac {b \sec ^2\left (\frac {1}{2} (e+f x)\right )}{8 f}+\frac {3 b \log \left (\sin \left (\frac {1}{2} (e+f x)\right )\right )}{2 f}-\frac {3 b \log \left (\cos \left (\frac {1}{2} (e+f x)\right )\right )}{2 f}+\frac {b \sin \left (\frac {1}{2} (e+f x)\right )}{f \left (\cos \left (\frac {1}{2} (e+f x)\right )-\sin \left (\frac {1}{2} (e+f x)\right )\right )}-\frac {b \sin \left (\frac {1}{2} (e+f x)\right )}{f \left (\sin \left (\frac {1}{2} (e+f x)\right )+\cos \left (\frac {1}{2} (e+f x)\right )\right )} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [B] time = 0.81, size = 124, normalized size = 2.34 \[ \frac {2 \, {\left (a + 3 \, b\right )} \cos \left (f x + e\right )^{2} - {\left ({\left (a + 3 \, b\right )} \cos \left (f x + e\right )^{3} - {\left (a + 3 \, b\right )} \cos \left (f x + e\right )\right )} \log \left (\frac {1}{2} \, \cos \left (f x + e\right ) + \frac {1}{2}\right ) + {\left ({\left (a + 3 \, b\right )} \cos \left (f x + e\right )^{3} - {\left (a + 3 \, b\right )} \cos \left (f x + e\right )\right )} \log \left (-\frac {1}{2} \, \cos \left (f x + e\right ) + \frac {1}{2}\right ) - 4 \, b}{4 \, {\left (f \cos \left (f x + e\right )^{3} - f \cos \left (f x + e\right )\right )}} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F(-2)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Exception raised: NotImplementedError} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [B] time = 0.97, size = 100, normalized size = 1.89 \[ -\frac {a \cot \left (f x +e \right ) \csc \left (f x +e \right )}{2 f}+\frac {a \ln \left (\csc \left (f x +e \right )-\cot \left (f x +e \right )\right )}{2 f}-\frac {b}{2 f \sin \left (f x +e \right )^{2} \cos \left (f x +e \right )}+\frac {3 b}{2 f \cos \left (f x +e \right )}+\frac {3 b \ln \left (\csc \left (f x +e \right )-\cot \left (f x +e \right )\right )}{2 f} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.39, size = 76, normalized size = 1.43 \[ -\frac {{\left (a + 3 \, b\right )} \log \left (\cos \left (f x + e\right ) + 1\right ) - {\left (a + 3 \, b\right )} \log \left (\cos \left (f x + e\right ) - 1\right ) - \frac {2 \, {\left ({\left (a + 3 \, b\right )} \cos \left (f x + e\right )^{2} - 2 \, b\right )}}{\cos \left (f x + e\right )^{3} - \cos \left (f x + e\right )}}{4 \, f} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 4.20, size = 62, normalized size = 1.17 \[ \frac {b-{\cos \left (e+f\,x\right )}^2\,\left (\frac {a}{2}+\frac {3\,b}{2}\right )}{f\,\left (\cos \left (e+f\,x\right )-{\cos \left (e+f\,x\right )}^3\right )}-\frac {\mathrm {atanh}\left (\cos \left (e+f\,x\right )\right )\,\left (\frac {a}{2}+\frac {3\,b}{2}\right )}{f} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \[ \int \left (a + b \sec ^{2}{\left (e + f x \right )}\right ) \csc ^{3}{\left (e + f x \right )}\, dx \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________